package com.momo.epidemic;

import org.springframework.web.servlet.support.AbstractAnnotationConfigDispatcherServletInitializer;

public class MyInitializer extends AbstractAnnotationConfigDispatcherServletInitializer {
//   spring的配置类
    @Override
    protected Class<?>[] getRootConfigClasses() {
        return new Class[]{springConfig.class};
    }
//  springmvc的配置类
    @Override
    protected Class<?>[] getServletConfigClasses() {
        return new Class[]{springMVCConfig.class};
    }
//返回DispatcherServlet印象
    @Override
    protected String[] getServletMappings() {
        return new String[]{"/"};
    }
}
